home *** CD-ROM | disk | FTP | other *** search
/ PC-SIG: World of Education / PC-SiG's World of Education.iso / run / 2602 / plotwt.alg < prev    next >
Encoding:
Text File  |  1990-08-12  |  1.1 KB  |  42 lines

  1. {PLOTWT - plots weight data}
  2. smooth = off;
  3. interp = off;
  4. step = 1;
  5. label = "J.J. KOCHY'S WEIGHT";
  6. ylabel="LBS";
  7. xlabel="1986 - 1990";
  8. xformat = dates;
  9.  
  10. file="weight.dat";
  11. jjkwt = read & scaley(jjkwt) &
  12. jjkavg = avg(jjkwt) & jjksigma = std.dev(jjkwt);
  13.  
  14.                  { plot weight and 1 standard deviation on each side }
  15. constant(jjksigma);
  16. tracenum = off;
  17. plot(jjkwt) & plot(jjkavg) & plot(jjkavg+jjksigma) & plot(jjkavg-jjksigma);
  18. constant(jjkavg);
  19. text = "Weight, Avg. Weight, and One Standard Deviation on Each Side";
  20. note(xposn(.05),yposn(.95));
  21. text = "Average weight = ";
  22. note(jjkavg,xposn(.05),yposn(.925));
  23. text = "Stand deviation = ";
  24. note(jjksigma,xposn(.05),yposn(.90));
  25. pause;
  26. group(read,read,read,read,read) &
  27. trace = box & plot(grpavg) & trace=line & plot(grpavg) &
  28. trace=vline & plot(bottom + grpmax - grpmin);
  29. pause;
  30.  
  31. erase;
  32. label = "Weight Distribution";
  33. ylabel = "Number of Weigh Ins";
  34. xlabel = "Pounds";
  35. xformat = nominal;
  36. interp = off;
  37. binset(50,150,200);
  38. bincnt(jjkwt);
  39. trace = vline;
  40. plot(bin(t));
  41. text="Bin Size (in LBs): "; note(10*stepval,xposn(.05),yposn(.95));
  42.